package br.fatec.model.entity;

import java.io.Serializable;

import javax.persistence.Embeddable;
import javax.persistence.FetchType;
import javax.persistence.ForeignKey;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;

@Embeddable
public class Semiacabado_SemiacabadoId implements Serializable {

	
	/**
	 * 
	 */
	private static final long serialVersionUID = 1092672632042331050L;

	@ManyToOne(fetch = FetchType.EAGER)
	@JoinColumn(nullable=false, updatable=false, foreignKey=@ForeignKey(name="fk_semiacabadopai_cod"))
	private Semiacabado semiAcabadoPai;
	
	@ManyToOne(fetch = FetchType.EAGER)
	@JoinColumn(nullable=false, updatable=false, foreignKey=@ForeignKey(name="fk_semiacabadofilho_cod"))
	private Semiacabado semiAcabadoFilho;

	public Semiacabado getSemiAcabadoPai() {
		return semiAcabadoPai;
	}

	public void setSemiAcabadoPai(Semiacabado semiAcabadoPai) {
		this.semiAcabadoPai = semiAcabadoPai;
	}

	public Semiacabado getSemiAcabadoFilho() {
		return semiAcabadoFilho;
	}

	public void setSemiAcabadoFilho(Semiacabado semiAcabadoFilho) {
		this.semiAcabadoFilho = semiAcabadoFilho;
	}
}
